<template>
	<!-- 地图 -->
	<view>
		<view class="">
			<view class="huiqu" @click="goNavigateBack"><u-icon class="top_icon" name="arrow-left" color="#000000" size="50"></u-icon></view>
			  <map class="map" :latitude="latitude" :longitude="longitude" :markers="covers"/>
		</view>
	</view>
</template>

<script>
	export default {
		data() {
			return {
				latitude: '',
				longitude: '',
				covers: [{
					latitude: 39.909,
					longitude: 116.39742,
					iconPath: 'https://z3.ax1x.com/2021/09/10/hjNU2R.png'
				}]
			}
		},
		onLoad(param) {
			this.init(param)
		},
		methods: {
			init(param){
				console.log("param", param)
				this.covers[0].latitude = this.latitude = param.lat
				this.covers[0].longitude = this.longitude = param.lng
			},
			goNavigateBack() {
				uni.navigateBack()
			},
			
		}
	}
</script>

<style>
	.map{
		width: 750rpx;
		height: 100vh;
	}
	.huiqu{
		position: fixed;
		left: 50rpx;
		top: 60rpx;
		width: 50rpx;
		height: 50rpx;
		background-color: #F1F1F1;
		z-index: 10;
	}
</style>
